package com.ecut.property_project.service.impl;

import com.ecut.property_project.mapper.character.RoleMapper;
import com.ecut.property_project.model.character.Role;
import com.ecut.property_project.service.RoleService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;

@Service
public class RoleServiceImpl implements RoleService {

    @Autowired
    RoleMapper roleMapper;
    @Override
    public List<Role> selectAll() {
        return roleMapper.selectAll();
    }

    @Override
    public List<Role> selectByPage(Integer page, Integer pageSize) { return roleMapper.selectByPage(page,pageSize);}

    @Override
    public List<Role> findRoleByRid(Integer rid) {
        return roleMapper.findRoleByRid(rid);
    }

    @Override
    public Boolean deleteUserRole(Integer id) {
        return roleMapper.deleteUserRole(id);
    }
}
